<!DOCTYPE html>
<html>
<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <title>后台登录</title>
    <meta name="keywords" content="游戏管理后台">
    <meta name="description" content="游戏">

    <link rel="shortcut icon" href="favicon.ico"> <link href="__PUBLIC__/admin/css/bootstrap.min14ed.css?v=3.3.6" rel="stylesheet">
    <link href="__PUBLIC__/admin/css/font-awesome.min93e3.css?v=4.4.0" rel="stylesheet">

    <link href="__PUBLIC__/admin/css/animate.min.css" rel="stylesheet">
    <link href="__PUBLIC__/admin/css/style.min862f.css?v=4.1.0" rel="stylesheet">

    <script>if(window.top !== window.self){ window.top.location = window.location;}</script>
</head>

<body class="gray-bg">

    <div class="middle-box text-center loginscreen  animated fadeInDown">
        <div>
            <div>

                <h3 class="logo-name" ><font size="20">游&nbsp;戏&nbsp;后&nbsp;台</font></h3>

            </div>


            <form class="m-t" role="form" action="{:U()}" method="post" onsubmit="return chkform2(this)">
                <div class="form-group">
                    <input type="text" class="form-control" placeholder="用户名" required="" name="username">
                </div>
                <div class="form-group">
                    <input type="password" class="form-control" placeholder="密码" required="" name="password">
                </div>
                <button type="submit" class="btn btn-primary block full-width m-b">登 录</button>            
                </p>

            </form>
        </div>
    </div>
    <script src="__PUBLIC__/admin/js/jquery.min.js?v=2.1.4"></script>
    <script src="__PUBLIC__/admin/js/bootstrap.min.js?v=3.3.6"></script>
    <script src="__PUBLIC__/admin/layer/layer.js"></script>
    <script type="text/javascript" src="http://tajs.qq.com/stats?sId=9051096" charset="UTF-8"></script>
    <script type="text/javascript">
        function chkform2(the){
            var that = $(the);
            var url= $(the).attr('action');
            var cs = $(the).serialize();
            //alert(url);

            $.ajax({
                url:url,
                data:cs,
                type:'POST',
                success: function(data){
                    console.log(data);
                    if(data.status==1){
                        layer.msg(data.info);
                        var timer = setInterval(function(){
                            clearInterval(timer);
                            window.location.href=data.url;
                        },2000);
                    }else{
                        layer.msg(data.info);

                    }
                }
            });

            return false;
        }
    </script>
</body>
</html>
